home *** CD-ROM | disk | FTP | other *** search
/ The Guinness Encyclopedia / The Guinness Encyclopedia - Wayzata Technology (3221-1B) (Disc 1) (1995).iso / mac / 16in_enc.ycl / stack.txt < prev    next >
Text File  |  1995-08-14  |  7KB  |  259 lines

  1. -- stack: in.ycl
  2. -- format: 10 (HyperCard 2)
  3. -- flags: 0x1000 (none)
  4. -- protect password hash: 0
  5. -- maximum user level: 5 (scripting)
  6. -- window: Rect(0, 39, 640, 519)
  7. -- screen: Rect(0, 0, 1024, 768)
  8. -- card dimensions: w=640 h=480
  9. -- scroll: x=0 y=0
  10. -- background count: 1
  11. -- first background id: 5472
  12. -- card count: 63
  13. -- first card id: 5265
  14. -- list block id: 35931
  15. -- print block id: 35754
  16. -- font table block id: 3573
  17. -- style table block id: 3106
  18. -- free block count: 49
  19. -- free size: 28992 bytes
  20. -- total size: 172032 bytes
  21. -- stack block size: 6144 bytes
  22. -- created by hypercard version: 0x02208000
  23. -- compacted by hypercard version: 0x02308000
  24. -- modified by hypercard version: 0x02208000
  25. -- opened by hypercard version: 0x02208000
  26. -- patterns[0]: 0x0000000000000000
  27. -- patterns[1]: 0x8000000008000000
  28. -- patterns[2]: 0x8800220088002200
  29. -- patterns[3]: 0x8888222288882222
  30. -- patterns[4]: 0x88AA22AA88AA22AA
  31. -- patterns[5]: 0xCCAA33AACCAA33AA
  32. -- patterns[6]: 0xEEAABBAAEEAABBAA
  33. -- patterns[7]: 0xEEBBBBEEEEBBBBEE
  34. -- patterns[8]: 0xFFBBFFEEFFBBFFEE
  35. -- patterns[9]: 0xFFBBFFFFFFBBFFFF
  36. -- patterns[10]: 0x8010022001084004
  37. -- patterns[11]: 0xFFFFFFFFFFFFFFFF
  38. -- patterns[12]: 0x8822882288228822
  39. -- patterns[13]: 0x1122448811224488
  40. -- patterns[14]: 0xC4800C6843023026
  41. -- patterns[15]: 0xB130031BD8C00C8D
  42. -- patterns[16]: 0xAA00AA00AA00AA00
  43. -- patterns[17]: 0x8822552288225522
  44. -- patterns[18]: 0x8855225588552255
  45. -- patterns[19]: 0x77DD77DD77DD77DD
  46. -- patterns[20]: 0x8000000000000000
  47. -- patterns[21]: 0xAA55AA55AA55AA55
  48. -- patterns[22]: 0x038448300C020101
  49. -- patterns[23]: 0x8244394482010101
  50. -- patterns[24]: 0x8814224188412214
  51. -- patterns[25]: 0x8080413E080814E3
  52. -- patterns[26]: 0x22048C7422179810
  53. -- patterns[27]: 0xBE808808EB088880
  54. -- patterns[28]: 0x25C8328964244C92
  55. -- patterns[29]: 0xA29C41BE2AC914EB
  56. -- patterns[30]: 0x40A00000040A0000
  57. -- patterns[31]: 0x8040200002040800
  58. -- patterns[32]: 0xAA00800088008000
  59. -- patterns[33]: 0xFF80808080808080
  60. -- patterns[34]: 0x081C22C180010204
  61. -- patterns[35]: 0xFF808080FF080808
  62. -- patterns[36]: 0xF87422478F172271
  63. -- patterns[37]: 0xBF00BFBFB0B0B0B0
  64. -- patterns[38]: 0xFF7FBE5DA2418000
  65. -- patterns[39]: 0xFAF5FAF5A050A050
  66. -- checksum: 0xDB6CE4E7
  67. ----- HyperTalk script -----
  68.  
  69. on resumeStack
  70.   disable menuItem "Print Text" of menu "File"
  71.   disable menuItem "Print Image" of menu "File"
  72.   enable menu "Edit"
  73.   enable menu "Go"
  74.   disable menuItem "Copy Text" of menu "Edit"
  75.   disable menuItem "Copy Image" of menu "Edit"
  76.  
  77. end resumeStack
  78.  
  79. on openCard
  80.  
  81.   Send colorMe to this card
  82.   -- put the number of lines in the voices into x
  83.   -- answer x
  84.  
  85.   pass openCard
  86.   unlock screen
  87. end openCard
  88.  
  89. on doMenu menuItem
  90.   -- put menuItem
  91.   if menuItem is "Go Back" then
  92.     WTIgoback
  93.   else if menuItem is "Help" then
  94.     WTIhelp
  95.     exit doMenu
  96.   else if menuItem is "Main" then
  97.     WTImain
  98.   else if menuItem is "Gallery" then
  99.     WTIgallery
  100.   else if menuItem is "Explorer" then
  101.     WTIexplore
  102.   else if menuItem is "Credits" then
  103.     WTIcredits
  104.   else if menuItem is "Encyclopedia" then
  105.     WTIencycl
  106.   else if menuItem is "Languages" then
  107.     go to card 1 of stack "Guinness:mac:language samples" in a new window
  108.   else if menuItem is "About Hypercard..." then
  109.     WTIcredits
  110.     exit doMenu
  111.   else if menuItem is "Quit Encyclopedia" then
  112.     doMenu "Quit HyperCard"
  113.     exit doMenu
  114.   end if
  115.  
  116.   pass doMenu
  117.  
  118. end doMenu
  119.  
  120. on WTIcredits
  121.   go to card 1 of stack "16in Credits"
  122. end WTIcredits
  123.  
  124. on closeCard
  125.   global lastCard, lastBook
  126.   put "encyclopedia" into lastBook
  127.   put the number of this card into lastCard
  128.   lock screen
  129.   pass closeCard
  130. end closeCard
  131.  
  132. on colorMe
  133.   AddColor colorCard,stamp,30
  134. end colorMe
  135.  
  136. on openStack
  137.   set lockscreen to true
  138.   AddColor install
  139.   disable menuItem "Print Text" of menu "File"
  140.   disable menuItem "Print Image" of menu "File"
  141.   enable menu "Edit"
  142.   enable menu "Go"
  143.   disable menuItem "Copy Text" of menu "Edit"
  144.   disable menuItem "Copy Image" of menu "Edit"
  145.   pass openStack
  146.   set lockscreen to false
  147. end openStack
  148.  
  149.  
  150. on closeStack
  151.   AddColor remove
  152.   pass closeStack
  153. end closeStack
  154.  
  155.  
  156. on WTIgoButton CardN
  157.   if charToNum( CardN ) = charToNum("x") then
  158.     go to card CardN
  159.     -- go to card CardN of stack "Guinness:Mac:encyclopedia"
  160.     -- go to card 1 of stack "Guinness:Mac:encyclopedia"
  161.   else
  162.     WTIgotoPage CardN
  163.   end if
  164. end WTIgoButton
  165.  
  166.  
  167.  
  168. on WTInext
  169.   go to next
  170. end WTInext
  171.  
  172. on WTIprevious
  173.   go to previous
  174. end WTIprevious
  175.  
  176.  
  177. on WTImain
  178.   go to card 1 of stack "Guinness:Mac:16in Main"
  179. end WTImain
  180.  
  181. on WTIhelp
  182.   go to card 1 of stack "Guinness:Mac:16in Help"
  183. end WTIhelp
  184.  
  185. on WTIquit
  186.   doMenu "Quit HyperCard"
  187. end WTIquit
  188.  
  189. on WTIexplore
  190.   go to card 1 of stack "Guinness:Mac:16in Explorer"
  191. end WTIexplore
  192.  
  193. on WTIgallery
  194.   go to card 1 of stack "Guinness:Mac:16in Gallery"
  195. end WTIgallery
  196.  
  197. on WTIencycl
  198.   go to card 1 of stack "Guinness:Mac:16in Encyclopedia"
  199. end WTIencycl
  200.  
  201. on WTIgoback
  202.   -- global lastCard, lastBook
  203.   -- go to card lastCard of lastBook
  204.   go to recent card
  205. end WTIgoback
  206.  
  207. on WTIgotopage CardN
  208.   -- go to card CardN
  209.   --  answer "go to card # " & CardN && "not in yet!"
  210.   -- put CharToNum(CardN) into pp
  211.   -- fix it
  212.   put trunc( ((CardN)/2) ) * 2 into pp
  213.   -- if pp -- make sure is even!!!
  214.   if pp < 10 then   -- pad with 000's
  215.     --put NumToChar(pp) into x
  216.     put "p00" & pp & "-1" into ppp
  217.   else if pp < 99 then
  218.     -- put NumToChar(pp) into x
  219.     put "p0" & pp & "-1" into ppp
  220.  
  221.   else
  222.     -- put NumToChar(pp) into x
  223.     put "p" & pp & "-1" into ppp
  224.   end if
  225.  
  226.   -- put CardN && pp && ppp && char 2 to 6 of ppp
  227.  
  228.   if last char of ppp is return then
  229.     delete last char of ppp
  230.   end if
  231.  
  232.   if pp < 74 then
  233.     go to card ppp of stack "Guinness:MAC:Nature:16in Nature"
  234.   else if pp < 106 then
  235.     go to card ppp of stack "Guinness:MAC:Earth:16in Earth"
  236.   else if pp < 198 then
  237.     go to card ppp of stack "Guinness:MAC:Living:16in Living"
  238.   else if pp < 252 then
  239.     go to card ppp of stack "Guinness:MAC:Human:16in Human"
  240.   else if pp < 302 then
  241.     go to card ppp of stack "Guinness:MAC:World:16in World"
  242.   else if pp < 358 then
  243.     go to card ppp of stack "Guinness:MAC:Technology:16in Technology"
  244.   else if pp < 456 then
  245.     go to card ppp of stack "Guinness:MAC:History:16in History"
  246.   else if pp < 498 then
  247.     go to card ppp of stack "Guinness:MAC:Religion:16in Religion"
  248.   else if pp < 566 then
  249.     go to card ppp of stack "Guinness:MAC:Arts:16in Arts"
  250.   else if pp < 600 then
  251.     go to card ppp of stack "Guinness:MAC:Music:16in Music"
  252.   else if pp < 656 then
  253.     go to card ppp of stack "Guinness:MAC:Language:16in Language"
  254.   else
  255.     answer "Sorry, Countries of the World is not available here."
  256.   end if
  257.  
  258. end WTIgotopage
  259.